package com.cn.namesrv;

import com.cn.remote.ChannelListener;
import io.netty.channel.ChannelHandlerContext;

public class ChannelEventImpl implements ChannelListener {

    private NameSrvController nameSrvController;

    public ChannelEventImpl(NameSrvController nameSrvController) {
        this.nameSrvController = nameSrvController;
    }

    @Override
    public void registerEvent(ChannelHandlerContext ctx) {

    }

    @Override
    public void unregisterEvent(ChannelHandlerContext ctx) {
        this.nameSrvController.getTopicRouteManager().unregister(ctx);
    }
}
